/* ===================================
   设置侧边栏样式
   =================================== */

#settings-sidebar {
  position: fixed;
  top: 20px;
  left: 20px;
  width: 300px;
  height: calc(100vh - 40px);
  overflow-y: auto !important;
  padding-top: 20px;
  box-sizing: border-box;
  margin-right: 0;
  order: -1;
  display: flex;
  flex-direction: column;
  scrollbar-width: thin;
  scrollbar-color: #cbd5e0 #f8fafc;
  direction: rtl;
}

#settings-sidebar > * {
  direction: ltr;
}

#settings-sidebar .settings-card {
  background-color: white;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  padding: 25px;
  margin-bottom: 15px;
  transition: box-shadow 0.2s;
}

#settings-sidebar .settings-card:hover {
  transform: none;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

#settings-sidebar .settings-card h2 {
  border-bottom: 2px solid #f0f0f0;
  padding-bottom: 12px;
  margin-bottom: 20px;
  color: #2c3e50;
  font-size: 1.6em;
  text-align: center;
}

#settings-sidebar .settings-card h3 {
  color: #3a4767;
  font-size: 1.2em;
  margin-bottom: 15px;
  display: flex;
  align-items: center;
}

#settings-sidebar .settings-card h3 .toggle-icon {
  margin-left: auto;
  color: #8492a6;
  font-size: 1em;
}

#settings-sidebar .settings-card h3 .toggle-icon:hover {
  color: #3498db;
}

#settings-sidebar .settings-card h3 .toggle-icon:before {
  content: none;
}

#settings-sidebar .settings-form > div {
  margin-bottom: 15px;
  position: relative;
}

#settings-sidebar label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

#settings-sidebar select,
#settings-sidebar input[type="number"],
#settings-sidebar input[type="text"] {
  width: 100%;
  padding: 12px;
  border: 1px solid #e0e6ed;
  border-radius: 8px;
  box-sizing: border-box;
  font-size: 1em;
  transition: border-color 0.3s, box-shadow 0.3s;
  background-color: #f9fafc;
}

#settings-sidebar select:focus,
#settings-sidebar input[type="number"]:focus,
#settings-sidebar input[type="text"]:focus {
  border-color: #3498db;
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
  outline: none;
}

#settings-sidebar .input-hint {
  font-size: 0.9em;
  color: #777;
  margin-top: 0.2em;
  display: block;
}

/* 导航按钮 */
#settings-sidebar .navigation-buttons {
  display: flex;
  gap: 10px;
  margin-top: 20px;
  justify-content: space-between;
  width: auto;
}

#settings-sidebar .navigation-buttons button {
  width: auto;
  padding: 12px 15px;
  background-color: #6c757d;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 0.9em;
  transition: background-color 0.3s;
  box-shadow: none;
  transform: none;
  font-weight: normal;
  white-space: nowrap;
}

#settings-sidebar .navigation-buttons button:hover {
  background-color: #5a6268;
}

#settings-sidebar .navigation-buttons button:disabled {
  background-color: #ccc;
  cursor: not-allowed;
}

/* 模型建议、提示词设置等样式已移除 - 这些功能现在由设置模态框处理 */

/* 字体设置区块 */
#settings-sidebar #font-settings {
  margin-top: 20px;
  border-top: 1px solid #eee;
  padding-top: 15px;
  padding-bottom: 15px;
  margin-bottom: 15px;
  transition: transform 0.2s, box-shadow 0.2s;
  border-radius: 8px;
  padding: 15px;
  background-color: #f8fafc;
}

#settings-sidebar #font-settings:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

#settings-sidebar #font-settings h3 {
  margin-bottom: 10px;
  margin-top: 0;
}

#settings-sidebar button#applyFontSettingsToAllButton {
  font-size: 0.9em;
  padding: 8px 15px;
  margin-top: 10px;
}

#settings-sidebar #font-settings + div {
  margin-top: 20px;
}

/* 单个模块悬浮效果 */
#settings-sidebar #font-settings {
  margin-bottom: 15px;
  transition: transform 0.2s, box-shadow 0.2s;
  border-radius: 8px;
  padding: 15px;
  background-color: #f8fafc;
}

#settings-sidebar #font-settings:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
}

/* section间距重置 */
#settings-sidebar div.settings-card {
  margin-bottom: 15px;
  transition: box-shadow 0.2s;
}

#settings-sidebar div.settings-card .collapsible-header.collapsed {
  margin-bottom: 0;
}

#settings-sidebar div.settings-card .collapsible-content.collapsed {
  padding-top: 0;
  padding-bottom: 0;
  margin-bottom: 0;
}

/* 描边设置 */
#settings-sidebar #strokeEnabled {
  margin-left: 5px;
  transform: scale(1.1);
}

#settings-sidebar #strokeOptions label {
  font-size: 0.95em;
}

/* 百度OCR和其他OCR选项样式已移除（这些设置现在在设置模态框中） */

/* 填充方式设置 */
#solidColorOptions, #inpaintingOptions {
  margin-top: 10px;
  margin-bottom: 10px;
  overflow: visible;
}
